package com.mc.lp.shared.vo;

import java.util.Collection;

import org.springframework.security.core.GrantedAuthority;
/**
 * this vo will h
 * old all information related to user and this will be pushed to session
 * @author deepak
 */
public class UserVO extends org.springframework.security.core.userdetails.User implements IValueObject{
	private static final long serialVersionUID = 1L;
	public UserVO(String username, String password, boolean enabled, boolean accountNonExpired, boolean credentialsNonExpired, boolean accountNonLocked,
			Collection<? extends GrantedAuthority> authorities) {
		super(username, password, enabled, accountNonExpired, credentialsNonExpired, accountNonLocked, authorities);

	}

	private Long roleId;
	private long userId;
	private String emailAddress;
	private String firstName;
	private String lastName;
	
	public long getUserId() {
		return userId;
	}
	public void setUserId(long userId) {
		this.userId = userId;
	}
	public String getEmailAddress() {
		return emailAddress;
	}
	public void setEmailAddress(String emailAddress) {
		this.emailAddress = emailAddress;
	}
	public String getFirstName() {
		return firstName;
	}
	public void setFirstName(String firstName) {
		this.firstName = firstName;
	}
	public String getLastName() {
		return lastName;
	}
	public void setLastName(String lastName) {
		this.lastName = lastName;
	}
	public static long getSerialversionuid() {
		return serialVersionUID;
	}
	
	public Long getRoleId() {
		return roleId;
	}
	public void setRoleId(Long roleId) {
		this.roleId = roleId;
	}
	@Override
	public String toString() {
		return super.toString() + "{"+getAuthorities()+"}";
	}
}